import request from "@/utils/request";

export default {
  //生成订单
  createOrders(courseId) {
    return request({
      url: `/orderservice/order/createOrder/${courseId}`,
      method: "post"
    });
  },
  //根据订单id查询订单
  byidOrder(id) {
    return request({
      url: `/orderservice/order/get/${id}`,
      method: "post"
    });
  },
  //生成微信支付二维码的方法
  createWx(orderNo) {
    return request({
      url: `/orderservice/paylog/createNative/${orderNo}`,
      method: "get"
    });
  },
  //查询订单的方法
  byidpay(orderNo) {
    return request({
      url: `/orderservice/paylog/get/${orderNo}`,
      method: "post"
    });
  }
};
